<?php
$this->load->view('layout/header', ["title"=> "接口调试首页"]);
$this->load->view('layout/topnav');
?>
<div style="margin:0px auto; margin-top:10px; width:1000px;">
  <ul>
    <li>接口名称：微信回调参数</li>
    <li>接口地址：</li>
    <li>接口方法：</li>
  </ul>
</div>

<br>
<table align="center" width="1000" cellpadding="0" cellspacing="1" style="border:1px solid #CCC">
  <form id="requestform">
  <tr bgcolor="#EEE" height="24">
    <td width="120">参数名</td>
    <td width="400">参数</td>
    <td>必填</td>
    <td>类型</td>
    <td>说明</td>
  </tr>
  <tr bgcolor="#F9F9F9" height="24">
    <td>请求地址</td>
      <td><select name="url">
              <option value="http://yuxun.aidiaowu.com:8083/v2/coin/wechat-notify">http://yuxun.aidiaowu.com:8083/v2/coin/wechat-notify</option>
          </select>

          </td>

          <td>是</td>
          <td>String</td>
          <td>支付宝回调参数</td>
      </tr>
  <tr bgcolor="#F9F9F9" height="24">
    <td>微信回调参数</td>

    <td height="500">
        <textarea id="jsonstr" name="jsonstr" rows="30" cols="60">{
    "appid":"wx5203628d7b2a6e0f",
    "bank_type":"CFT",
    "cash_fee":"1",
    "fee_type":"CNY",
    "is_subscribe":"N",
    "mch_id":"1494857612",
    "nonce_str":"E4b3Vwa8MYClmldD",
    "openid":"oNLj6w-pTiWhRUIIPthBhfFrXAf8",
    "out_trade_no":"1903113583723568",
    "result_code":"SUCCESS",
    "return_code":"SUCCESS",
    "sign":"99B66E3A335B284E4D3FCA2E65DFF1B0",
    "time_end":"20190311181054",
    "total_fee":"1",
    "trade_type":"APP",
    "transaction_id":"4200000284201903118824392249"
}
        </textarea>
    </td>

    <td>是</td>
    <td>XML</td>
    <td>支付宝回调参数</td>
  </tr>


  <tr bgcolor="#F9F9F9" height="24">
    <td colspan="5" align="center">
		<input type="button" value="request_post" onclick="request_post()"/>
		<input type="button" value="CURL RAW" onclick="request_curl_raw()"/>
		<input type="button" value="直接请求" onclick="direct()"/>
    </td>
  </tr>
  </form>
</table>
<script language="javascript">

function request_post(){
    var $form = $('#requestform');
    $form.attr('method', 'POST');
    //$form.append($('<input type="text" name="uri" value="'+uri+'"/>'));
    $form.attr('action', "");
    $form.submit();
}

</script>
</body>
</html>